<?php
require_once 'const/DBConst.php';
?>

<div id="locate"><div id="ps"><span id="topnav"><a href="/">首页</a> &raquo; 商品 </span> </div></div>
<!-- -->
<div id="container"><div class='mallLogin'> <span class='welcome'>最热商品</span></div>
    <div class="content">
        <div class="compareList">
            <ul class="shoppingTab" style="width:945px;">
                <li class="cur" id="tab1">商品</li>
            </ul>
            <div id="con1">
                <!-- -->
                <div class="list">
                    <div class="productList">
                        <ul>
                            <?php foreach ($this->products as $product): ?>
                                <li>
                                    <a href="<?php echo "/product/view?id=" . $product["ID"] ?>" target="_blank" class="productImg" title="<?php echo $product[C_NAME] ?>">
                                        <img height="200" src="<?php echo "/upload/" . $product["ID"] ?>" alt="<?php echo $product[C_NAME] ?>" onerror="this.src='/imags/nopic.gif'" />
                                    </a>
                                    <p class="name">
                                        <a href="<?php echo "/product/view?id=" . $product["ID"] ?>" target="_blank" title="<?php echo $product[C_NAME] ?>"><?php echo $product[C_NAME] ?></a>
                                    </p>
                                    <p class="pricelabel">
                                        售　价:              <font color="#FF0000"> &yen; </font><?php echo $product[C_PRICE] ?>
                                    </p>
                                    <p class="pricelabel">
                                        库 存:              <?php echo $product[C_NUM] ?>
                                    </p>
                                    <p class="pricelabel">
                                        热 度:              <?php echo $product[C_BUY_TIMES] ?>
                                    </p>
                                </li>
                            <?php endforeach; ?>

                        </ul>
                    </div>
                </div>
                <!-- -->
            </div>
        </div>
    </div>
</div> 